3.83 \(\int \frac {1-x^2}{1+3 x^2+x^4} \, dx\)

Optimal. Leaf size=39 \[ \tan ^{-1}\left (\sqrt {\frac {1}{2} \left (3+\sqrt {5}\right )} x\right )-\tan ^{-1}\left (\sqrt {\frac {2}{3+\sqrt {5}}} x\right ) \]

[Out]

-arctan(x*2^(1/2)/(3+5^(1/2))^(1/2))+arctan(x*(1/2+1/2*5^(1/2)))

________________________________________________________________________________________

Rubi [A]  time = 0.03, antiderivative size = 39, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 2, integrand size = 20, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.100, Rules used = {1163, 203} \[ \tan ^{-1}\left (\sqrt {\frac {1}{2} \left (3+\sqrt {5}\right )} x\right )-\tan ^{-1}\left (\sqrt {\frac {2}{3+\sqrt {5}}} x\right ) \]

Antiderivative was successfully verified.

[In]

Int[(1 - x^2)/(1 + 3*x^2 + x^4),x]

[Out]

-ArcTan[Sqrt[2/(3 + Sqrt[5])]*x] + ArcTan[Sqrt[(3 + Sqrt[5])/2]*x]

Rule 203

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1*ArcTan[(Rt[b, 2]*x)/Rt[a, 2]])/(Rt[a, 2]*Rt[b, 2]), x] /;
 FreeQ[{a, b}, x] && PosQ[a/b] && (GtQ[a, 0] || GtQ[b, 0])

Rule 1163

Int[((d_) + (e_.)*(x_)^2)/((a_) + (b_.)*(x_)^2 + (c_.)*(x_)^4), x_Symbol] :> With[{q = Rt[b^2 - 4*a*c, 2]}, Di
st[e/2 + (2*c*d - b*e)/(2*q), Int[1/(b/2 - q/2 + c*x^2), x], x] + Dist[e/2 - (2*c*d - b*e)/(2*q), Int[1/(b/2 +
 q/2 + c*x^2), x], x]] /; FreeQ[{a, b, c, d, e}, x] && NeQ[b^2 - 4*a*c, 0] && EqQ[c*d^2 - a*e^2, 0] && GtQ[b^2
 - 4*a*c, 0]

Rubi steps

\begin {align*} \int \frac {1-x^2}{1+3 x^2+x^4} \, dx &=\frac {1}{2} \left (-1-\sqrt {5}\right ) \int \frac {1}{\frac {3}{2}+\frac {\sqrt {5}}{2}+x^2} \, dx+\frac {1}{2} \left (-1+\sqrt {5}\right ) \int \frac {1}{\frac {3}{2}-\frac {\sqrt {5}}{2}+x^2} \, dx\\ &=-\tan ^{-1}\left (\sqrt {\frac {2}{3+\sqrt {5}}} x\right )+\tan ^{-1}\left (\sqrt {\frac {1}{2} \left (3+\sqrt {5}\right )} x\right )\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.01, size = 10, normalized size = 0.26 \[ \tan ^{-1}\left (\frac {x}{x^2+1}\right ) \]

Antiderivative was successfully verified.

[In]

Integrate[(1 - x^2)/(1 + 3*x^2 + x^4),x]

[Out]

ArcTan[x/(1 + x^2)]

________________________________________________________________________________________

fricas [A]  time = 0.44, size = 13, normalized size = 0.33 \[ \arctan \left (x^{3} + 2 \, x\right ) - \arctan \relax (x) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-x^2+1)/(x^4+3*x^2+1),x, algorithm="fricas")

[Out]

arctan(x^3 + 2*x) - arctan(x)

________________________________________________________________________________________

giac [A]  time = 0.18, size = 26, normalized size = 0.67 \[ \frac {1}{4} \, \pi \mathrm {sgn}\relax (x) - \frac {1}{2} \, \arctan \left (\frac {x^{4} + x^{2} + 1}{2 \, {\left (x^{3} + x\right )}}\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-x^2+1)/(x^4+3*x^2+1),x, algorithm="giac")

[Out]

1/4*pi*sgn(x) - 1/2*arctan(1/2*(x^4 + x^2 + 1)/(x^3 + x))

________________________________________________________________________________________

maple [B]  time = 0.02, size = 104, normalized size = 2.67 \[ \frac {2 \sqrt {5}\, \arctan \left (\frac {4 x}{2 \sqrt {5}-2}\right )}{2 \sqrt {5}-2}-\frac {2 \arctan \left (\frac {4 x}{2 \sqrt {5}-2}\right )}{2 \sqrt {5}-2}-\frac {2 \sqrt {5}\, \arctan \left (\frac {4 x}{2 \sqrt {5}+2}\right )}{2 \sqrt {5}+2}-\frac {2 \arctan \left (\frac {4 x}{2 \sqrt {5}+2}\right )}{2 \sqrt {5}+2} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((-x^2+1)/(x^4+3*x^2+1),x)

[Out]

-2*5^(1/2)/(2*5^(1/2)+2)*arctan(4/(2*5^(1/2)+2)*x)-2/(2*5^(1/2)+2)*arctan(4/(2*5^(1/2)+2)*x)+2*5^(1/2)/(2*5^(1
/2)-2)*arctan(4/(2*5^(1/2)-2)*x)-2/(2*5^(1/2)-2)*arctan(4/(2*5^(1/2)-2)*x)

________________________________________________________________________________________

maxima [F]  time = 0.00, size = 0, normalized size = 0.00 \[ -\int \frac {x^{2} - 1}{x^{4} + 3 \, x^{2} + 1}\,{d x} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-x^2+1)/(x^4+3*x^2+1),x, algorithm="maxima")

[Out]

-integrate((x^2 - 1)/(x^4 + 3*x^2 + 1), x)

________________________________________________________________________________________

mupad [B]  time = 4.31, size = 13, normalized size = 0.33 \[ \mathrm {atan}\left (x^3+2\,x\right )-\mathrm {atan}\relax (x) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(-(x^2 - 1)/(3*x^2 + x^4 + 1),x)

[Out]

atan(2*x + x^3) - atan(x)

________________________________________________________________________________________

sympy [A]  time = 0.12, size = 10, normalized size = 0.26 \[ - \operatorname {atan}{\relax (x )} + \operatorname {atan}{\left (x^{3} + 2 x \right )} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-x**2+1)/(x**4+3*x**2+1),x)

[Out]

-atan(x) + atan(x**3 + 2*x)

________________________________________________________________________________________